#ifndef Foundation_Foundation_INCLUDED
#define Foundation_Foundation_INCLUDED


//
// Include library configuration
//
#include "wch/Config.h"

//
// Include platform-specific definitions
//
#include "wch/Platform.h"
#if defined(_WIN32)
	#include "wch/Platform_WIN32.h"
#elif defined(__VMS)
	#include "wch/Platform_VMS.h"
#elif defined(GTS_VXWORKS)
	#include "wch/Platform_VX.h"
#elif defined(GTS_OS_FAMILY_UNIX)
	#include "wch/Platform_POSIX.h"
#endif


//
// Cleanup inconsistencies
//
#ifdef GTS_OS_FAMILY_WINDOWS
	#if defined(GTS_WIN32_UTF8) && defined(GTS_NO_WSTRING)
		#error GTS_WIN32_UTF8 and GTS_NO_WSTRING are mutually exclusive.
	#endif
#else
	#ifdef GTS_WIN32_UTF8
		#undef GTS_WIN32_UTF8
	#endif
#endif


//
// GTS_JOIN
//
// The following piece of macro magic joins the two
// arguments together, even when one of the arguments is
// itself a macro (see 16.3.1 in C++ standard).  The key
// is that macro expansion of macro arguments does not
// occur in GTS_DO_JOIN2 but does in GTS_DO_JOIN.
//
#define GTS_JOIN(X, Y) GTS_DO_JOIN(X, Y)
#define GTS_DO_JOIN(X, Y) GTS_DO_JOIN2(X, Y)
#define GTS_DO_JOIN2(X, Y) X##Y


//
// Pull in basic definitions
//
#include "wch/Bugcheck.h"
#include "wch/Types.h"
#include <string>


#endif // Foundation_Foundation_INCLUDED
